{extend name="base" /}
{block name="body"}
<div class="layui-body">
    <!--tab标签-->
    <div class="layui-tab layui-tab-brief">
        <ul class="layui-tab-title">
            <li class=""><a href="{:url('admin/good/index')}">商品管理</a></li>
            <li class="layui-this">添加商品</li>
        </ul>
        <div class="layui-tab-content">
            <div class="layui-tab-item layui-show">
                <form class="layui-form form-container" action="{:url('admin/good/save')}" method="post">
                    <div class="layui-form-item">
                        <label class="layui-form-label">名称</label>
                        <div class="layui-input-block">
                            <input type="text" name="name" value="" lay-verify="required" placeholder="请输入名称" class="layui-input" required>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">图片</label>
                        <div class="layui-input-block">
                            <input type="text" name="image" value="" placeholder="请上传图片" class="layui-input layui-input-inline" id="thumb" readonly required>
                            <input type="file" name="file" class="layui-upload-file">
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">商品属性</label>
                        <div class="layui-input-block">
                            <input type="text" name="attribute" value="" lay-verify="required" placeholder="请输入商品属性" class="layui-input" required>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">价格</label>
                        <div class="layui-input-block">
                            <input type="number" name="price" value="" lay-verify="required" placeholder="请输入价格" class="layui-input" required>
                        </div>
                    </div>
                    <!--<div class="layui-form-item">-->
                        <!--<label class="layui-form-label">原价</label>-->
                        <!--<div class="layui-input-block">-->
                            <!--<input type="number" name="fake_price" value="" placeholder="（选填）请输入原价" class="layui-input">-->
                        <!--</div>-->
                    <!--</div>-->
                    <!--<div class="layui-form-item">-->
                        <!--<label class="layui-form-label">购买可得积分</label>-->
                        <!--<div class="layui-input-block">-->
                            <!--<input type="number" name="integral" value="" lay-verify="required" placeholder="请输入积分" class="layui-input" required>-->
                        <!--</div>-->
                    <!--</div>-->
                    <div class="layui-form-item">
                        <label class="layui-form-label">介绍</label>
                        <div class="layui-input-block">
                            <textarea name="brief" placeholder="请输入介绍" class="layui-textarea" maxlength="200" required></textarea>
                        </div>
                    </div>

                    <div class="layui-form-item">
                        <label class="layui-form-label">内容</label>
                        <div class="layui-input-block">
                            <textarea name="content" placeholder="" class="layui-textarea" id="content" required></textarea>
                        </div>
                    </div>

                    <!--<div class="layui-form-item">-->
                        <!--<label class="layui-form-label">运费模式</label>-->
                        <!--<div class="layui-input-block">-->
                            <!--<input type="radio" name="freight_type" value="0" title="总计费" checked="checked">-->
                            <!--<input type="radio" name="freight_type" value="1" title="单件计费">-->
                        <!--</div>-->
                    <!--</div>-->
                    <!--<div class="layui-form-item">-->
                        <!--<label class="layui-form-label">运费价格</label>-->
                        <!--<div class="layui-input-block">-->
                            <!--<input type="number" name="freight" value=""  lay-verify="required" placeholder="请输入运费价格" class="layui-input" required>-->
                        <!--</div>-->
                    <!--</div>-->
                    <div class="layui-form-item">
                        <div class="layui-input-block">
                            <button class="layui-btn" lay-submit lay-filter="*">保存</button>
                            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
{/block}
{block name="js"}
<script src="__JS__/ueditor/ueditor.config.js"></script>
<script src="__JS__/ueditor/ueditor.all.min.js"></script>
{/block}
{block name="script"}
<script>
    var ue = UE.getEditor('content');
</script>
{/block}